home *** CD-ROM | disk | FTP | other *** search
/ Night Owl 6 / Night Owl's Shareware - PDSI-006 - Night Owl Corp (1990).iso / 008a / fglqbx10.zip / 10-05.BAS < prev    next >
BASIC Source File  |  1991-06-07  |  1KB  |  53 lines

  1. REM $INCLUDE: 'fastgraf.bi'
  2.  
  3. DEFINT A-Z
  4.  
  5. CONST Visual = 0
  6. CONST Hidden = 1
  7.  
  8. Status = SETMEM(-1*(64000+16))
  9.  
  10. REM initialize the video environment
  11.  
  12. NewMode = FGbestmode(320,200,2)
  13. IF NewMode < 0 OR NewMode = 12 THEN
  14.    PRINT "This program requires a 320 x 200 color graphics mode."
  15.    STOP
  16. END IF
  17. OldMode = FGgetmode
  18. FGsetmode NewMode
  19. Status = FGallocate(Hidden)
  20.  
  21. REM draw the background in the upper left corner
  22.  
  23. FGsetpage Hidden
  24. FGsetcolor 1
  25. FGrect 0, 95, 0, 49
  26. FGsetcolor 15
  27. FGmove 48, 25
  28. FGellipse 20, 20
  29.  
  30. REM copy it to the center of the visual page
  31.  
  32. FGtransfer 0, 95, 0, 49, 112, 124, Hidden, Visual
  33.  
  34. REM slide the object across the background three times
  35.  
  36. FGsetcolor 10
  37. FOR I = 0 TO 35
  38.    Frame  = I MOD 12
  39.    Offset = 10 * Frame - 10
  40.    FGtransfer 0, 95, 20, 29, 112, 105, Hidden, Hidden
  41.    FGrect 112+Offset, 131+Offset, 96, 105
  42.    FGtransfer 112, 207, 96, 105, 112, 105, Hidden, Visual
  43.    FGwaitfor 2
  44. NEXT
  45.  
  46. REM restore the original video mode and return to DOS
  47.  
  48. Status = FGfreepage(Hidden)
  49. FGsetmode OldMode
  50. FGreset
  51.  
  52. END
  53.